//common
$(function(){ 
	//全选与反选
	var ObjFbatch = $("#Fbatch");
	if(ObjFbatch.length>0){
		$("#Fbatch").click(function(){
			var tag = ObjFbatch.attr("checked");
			$("input[name='tag']").attr("checked",tag);
		});
	}	
});

function messages(secs,msg){
	$("#messages").html("");
	$("#messages").append('<div id="msg" class="message success close" style="display:block;"><p>'+msg+'<br />提示框<b id="sec" class="red">'+secs+'</b>秒后消失...</p></div>');
	$("#messages").show('slow');
	if(secs!=0){
		countDown(secs);
	}
}
function countDown(secs){
   $("#sec").html(secs);
   if(--secs>0)setTimeout( "countDown(" +secs+ ")" ,1000);
   if(secs==0){
	   $("#messages").hide('slow')
   }
}

function selflo(url){
	window.location.href=url;
}

function selfWOpen(url){
	window.open(url);
}

menu=function(obj,url){
	$("a[name='menu']").attr("class","");
	$("span").remove(".ui-icon-circle-arrow-n");
	$(obj).addClass("nvaa");
	$(obj).append('<span id="uimenu" class="ui-icon ui-icon-circle-arrow-n" style="float:left"></span>');
}